<script lang="ts" setup>
  import type { ICity } from '@/types/data';

  import CityListItem from './ListItem.vue';

  interface IProps {
    list: ICity[];
  }

  const props = withDefaults(defineProps<IProps>(), {
    list: []
  });
</script>

<template>
  <div class="list-wrapper">
    <city-list-item
      v-for="item of props.list"
      :key="item.cityId"
      v-bind="item"
    />
  </div>
</template>

<style scoped lang="scss">
  @import "./List.scss";
</style>
